package com.ruoyi.dynamic.model.pojo.request.app;


import com.ruoyi.common.core.annotation.valid.group.ValidGroup;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotNull;

@Getter
@Setter
@Schema(description = "APP-心愿单添加编辑参数")
public class AppRoomWishAddOrEditRequest {

    @Schema(description = "记录id")
    private Long id = 0L;

    @Schema(description = "礼物id")
    @NotNull(message = "礼物不能为空", groups = {ValidGroup.Insert.class, ValidGroup.Update.class})
    private Long giftId;

    @Schema(description = "数量")
    @NotNull(message = "数量不能为空", groups = {ValidGroup.Update.class, ValidGroup.Insert.class})
    @DecimalMin(value = "1", message = "数量最小为1")
    private Integer number;

    @Schema(description = "位置")
    @NotNull(message = "位置不能为空")
    private Integer sort;
}
